package com.gxwy.kaihu.controller;

import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import com.gxwy.kaihu.form.KaihuRequestForm;
import com.gxwy.kaihu.service.KaihuRequestService;

@Controller
@RequestMapping("/yonghuziliao")
public class RightController {
	
	@Autowired
	private KaihuRequestService service;
	
	@RequestMapping("/right")
	public String right(Model model,HttpSession session){
		String username=(String) session.getAttribute("username");
		KaihuRequestForm list=service.findByNo(username);			
//		int size=list.size();
		model.addAttribute("yonghuziliao",list);
//		model.addAttribute("size",size);
		return "right";
	}

}
